<?php
    if (file_exists("../data/ProductoAlmacenDA.php")) {
        include_once("../data/ProductoAlmacenDA.php");
    }
    if (file_exists("../entity/ProductoAlmacen.php")) {
        include_once("../entity/ProductoAlmacen.php");
    }
    
    class ProductoAlmacenBR{
        public $context;
        public function ProductoAlmacenBR(){
            $this->context = new ProductoAlmacenDA();
        }
        public function insertar($entity){
            $registros = $this->context->insertar($entity);
            return $registros;
        }
        public function validarEliminar($codigo){
            $registros = $this->context->validarEliminar($codigo);
            return $registros;
        }
        public function validarGrabar($codigo){
            $registros = $this->context->validarGrabar($codigo);
            return $registros;
        }
        public function eliminar($entity){
            $registros = $this->context->eliminar($entity);
            return $registros;
        }
        public function numeroRegistro($codigo,$producto,$cod_almacen){
            return $this->context->numeroRegistro($codigo,$producto,$cod_almacen);
        }
        public function BuscarSearch($entity ,$start=1, $limit=100,$sidx=1,$sord=""){
            $registros = $this->context->BuscarSearch($entity,$start , $limit,$sidx,$sord);
            return $registros;
        }
        public function contarStockMinimo(){
            $registros = $this->context->contarStockMinimo();
            return $registros;
        }
        public function numeroRegistro1(){
            return $this->context->numeroRegistro1();
        }
        public function BuscarSearch1($start=1, $limit=100,$sidx=1,$sord=""){
            $registros = $this->context->BuscarSearch1($start , $limit,$sidx,$sord);
            return $registros;
        }
    }
?>